<div class="wrapper-md">
	<form name="addForm" class="form-validation form-horizontal">
		<div class="form-group">
			<div class="col-sm-2 control-label">
				<label translate="sysConfig.mailSMTP"></label>
			</div>
			<div class="col-sm-4">
				<input type="text" id="smtpServer" class="form-control" ng-model="vm.mail.mail_smtp_server" ng-trim="true" name="smtpServer"
					required ng-minlength="1" ng-maxlength="256" />
				<span class="help-block m-b-none" >{{app.getMessage('common.op.remind0',[1,256])}}</span>
			</div>
		</div>
		<div class="form-group">
			<div class="col-sm-2 control-label">
				<label translate="sysConfig.account"></label>
			</div>
			<div class="col-sm-4">
				<input type="text" id="smtpServerUserName" class="form-control" ng-model="vm.mail.mail_account" ng-trim="true"
					required ng-minlength="1" ng-maxlength="50" />
				<span class="help-block m-b-none">{{app.getMessage('common.op.remind0',[1,50])}}</span>
			</div>
		</div>
		<div class="form-group">
			<div class="col-sm-2 control-label">
				<label translate="common.password"></label>
			</div>
			<div class="col-sm-4">
				<input type="password" id="smtpServerUserPassword" class="form-control" ng-trim="true" ng-model="vm.mail.mail_password"
					required ng-minlength="1" ng-maxlength="20" />
				<span class="help-block m-b-none">{{app.getMessage('common.op.remind0',[1,20])}}</span>
			</div>
		</div>
		<div class="form-group">
			<div class="col-sm-2 control-label">
				<label translate="sysConfig.sendSwitch"></label>
			</div>
			<div class="col-sm-4">
				<select class="form-control" id="emailType" name="emailType" ng-model="vm.mail.mail_send">
					<option value="off" translate="common.no"></option>
					<option value="on" translate="common.yes"></option>
				</select>
			</div>
		</div>
		<div class="form-group">
			<div class="col-sm-2 control-label">
				<label translate="sysConfig.LanguageSwitch"></label>
			</div>
			<div class="col-sm-4">
				<select class="form-control" name="mail_lang" ng-model="vm.mail.mail_lang"
					ng-options="lang.description for lang in vm.langs">
				</select>
			</div>
		</div>
		<div class="form-group col-sm-6 text-center">
			<button class="btn btn-primary m-r" ng-click="vm.testLink()" 
				ng-disabled="addForm.$invalid" translate="sysConfig.testLink"></button>
			<button class="btn btn-primary m-r" ng-click="vm.mailSubmit()" 
				ng-disabled="addForm.$invalid || !vm.mailTestFlag" translate="common.confirm"></button>
			<button class="btn btn-default" ng-click="vm.reloadPage(0)" translate="common.cancel"></button>
		</div>
	</form>
</div>